<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 200px; height: 200px; margin: 100px auto;
            background-color: #ccc;
            background-image: radial-gradient(circle at 10% 10%, red, black, blue);
            /* 线型渐变 */
            /* background-image: linear-gradient(5deg, red 20%, #ccc 20%, #000 80%) */
            /*  */
        }
    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>